1. Field of the Invention
The present invention relates to a power semiconductor device and, more particularly, to a technique for detecting the load current of a motor for an automotive vehicle, and the like.
2. Description of the Background Art
Background art current detection of power semiconductor devices for driving motors for automotive vehicles and the like has generally employed a Hall element or a combination of a shunt resistor and a linear isolation amplifier. Recently, a power semiconductor device employing a combination of a shunt resistor and an HVIC (high voltage IC) has made its appearance as a less expensive power semiconductor device than those described above. The HVIC is a control element which performs inverse level shift from a voltage on the high side of the shunt resistor to a voltage on the low side thereof, and has a PWM (pulse width modulation) function for converting the value of a voltage developed across the shunt resistor into a pulse width. A pulse is outputted from the HVIC through an I/O bus to a CPU which in turn measures the pulse width thereof to convert the pulse width into numerical data.
Examples of the power semiconductor devices which measure the pulse width of the pulse subjected to the PWM are disclosed in, for example, Japanese Patent Application Laid-Open No. 8-66049 (1996) and Japanese Patent Application Laid-Open No. 2002-34263.
For the background art current detection of the power semiconductor devices, an interrupt function or an input capture function of the CPU is used to measure the pulse width.
However, the use of the interrupt function is disadvantageous in that the increased load on the CPU impairs a real time property or decreases the accuracy of measurement.
The use of the input capture function, which is normally used to read an encoder, is disadvantageous in that there are not enough channels to read pulses from the HVIC.
A reference clock for a typical CPU is multiplied in the CPU but has a frequency too low for use in reading the above-mentioned pulses. This presents a problem such that the accuracy of measurement might decrease. For instance, currently commercially available HVICs with the inverse level shift function which have the highest carrier frequency include IR2172 from International Rectifier (40 kHz). If the reference frequency of the reference clock is 10 MHz and a full scale current value is 500 A, increased error of 500 A×(40 kHz/10 MHz)=2A results in the low accuracy of measurement.
A current feedback period is normally in synchronism with inverter control PWM carrier interrupt, and is required to have a response about one-tenth of an inverter control PWM carrier period. Thus, when the inverter control PWM carrier period is 100 to 200 μs, the current feedback period must have a response of 10 to 20 μs. On the other hand, when the carrier frequency of the HVIC is 40 kHz as mentioned above, the carrier period of the HVIC is 25 μs. Then, if the CPU and the HVIC are asynchronous to each other, a delay of up to 25 μs×2=50 μs occurs between the reading of a pulse and the measurement of the pulse width. This presents a problem that the response is slow in some cases.
Since the above-mentioned delay of 50 μs is varied depending on how much the CPU and the HVIC are out of sync with each other, the variation ranges from 0 to 50 μs. It is, therefore, more difficult for the power semiconductor device employing the shunt resistor and the HVIC for current detection to make corrections and, accordingly, to increase gain than the power semiconductor device employing the Hall element which exhibits the smaller variations for current detection. (As an example, if an output frequency is 500 Hz, the period is 2 ms, and therefore the variation of 50 μs corresponds to 2.5% fluctuation.)